﻿@model BrnMall.Core.PrintConfig

@section header{
    <title>添加打印机-订单管理</title>
    <script src='http://@ViewData["JSIP"]/CLodopfuncs.js'></script>
<link type="text/css" rel="stylesheet" href="/admin_store/css/site.css" />
    <script type="text/javascript" src="/admin_store/scripts/jquery.js"></script>
    <script type="text/javascript">
        //获取远程电脑的打印机数
        //var LODOP; //声明为全局变量 
        //function getPrinterCount() {	
        //    LODOP=getCLodop();
        //    var mySelect = document.getElementById("myselect");
        //    mySelect.options.length = 0;//先清空
        //    for(var i = 0;i < LODOP.GET_PRINTER_COUNT();i++){
        //        mySelect.options.add(new Option(LODOP.GET_PRINTER_NAME(i),i));
        //    }
        //};
        //window.onload = getPrinterCount;
        function clickJS() {
            document.getElementById('myselect').options.length = 0;
            LODOP = getCLodop();
            var JSIP = 'http://@ViewData["JSIP"]/CLodopfuncs.js';
            CLODOP.Create_Printer_List(document.getElementById('myselect'));
        }
        window.onload = clickJS;
    </script>
}
@section body{
    <h1 class="rightH1">
        微信小程序 &gt; 订单管理 &gt; 打印机设置 &gt; <span class="rightH1-cur">添加打印机</span> 
        <div class="right">
            <a href="@Html.Raw(ViewData["referer"].ToString())" class="menuBT">
                <img src="/admin_store/images/goback.jpg" />返回列表
            </a>
            <div class="clear">
            </div>
        </div>
        <div class="clear">
        </div>
    </h1>

    @using (Html.BeginForm("PrintConfig_Add", "Order"))
    {
        <div class="addTable">
            <table width="100%">
                <tr>
                    <td align="right">
                        打印机名称：
                    </td>
                    <td>
                        <select name="PrintID" id="myselect"></select>
                    </td>
            </tr>
                <tr>
                    <td></td>
                    <td><select name="PrintFormat">
                        <option value="60">60制式</option>
                        <option value="80">80制式</option>
                        </select></td>
                </tr>
            <tr>
                <td align="right">
                    &nbsp;
                </td>
                <td>
                    <a href="" class="addBt submit" id="sumbitBut">
                        <img src="/admin_store/images/submit.jpg" />
                    </a>
                    <script type="text/javascript">
                        $(function () {
                            $("#sumbitBut").click(function () {
                                $("form:first").submit();
                                return false;
                            })
                        });
                    </script>
                </td>
            </tr>
            <tr>
                <td align="right">
                    &nbsp;
                </td>
                <td>
                    &nbsp;
                </td>
            </tr>
        </table>
    </div>

    }
}
